from django.conf.urls.defaults import *
from widpy.buscar import views
from widpy.widpylogin.views import *
from django.contrib.auth.views import login


# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()


urlpatterns = patterns('',
    # Example:
    # (r'^prueba_busq/', include('prueba_busq.foo.urls')),

    # Uncomment the admin/doc line below and add 'django.contrib.admindocs' 
    # to INSTALLED_APPS to enable admin documentation:
    # (r'^admin/doc/', include('django.contrib.admindocs.urls')),

    # Uncomment the next line to enable the admin:
    (r'^admin/', include(admin.site.urls)),
    #(r'', 'prueba_busq.buscar.views.buscar'),
    #(r'^search_form/$', 'prueba_busq.buscar.views.search_form'),
    (r'^search/$', 'widpy.buscar.views.search'),
    (r'^search/info/w/(?P<widget_id>\d+)/comment/$', 'widpy.verinfo.views.wcomment'),
    (r'^search/info/w/(?P<widget_id>\d+)/wdel/$', 'widpy.verinfo.views.wdel'),
    (r'^search/info/t/(?P<tema_id>\d+)/comment/$', 'widpy.verinfo.views.tcomment'),
    (r'^search/info/t/(?P<widget_id>\d+)/tdel/$', 'widpy.verinfo.views.tdel'),
    (r'^search/info/w/(?P<widget_id>\d+)/$', 'widpy.verinfo.views.wdetail'),
    (r'^search/info/t/(?P<tema_id>\d+)/$', 'widpy.verinfo.views.tdetail'),
    (r'^search/add_widget/(?P<w_id>\d+)/$', 'widpy.ecodatos.views.add_widget'),
    (r'^addtab/', 'widpy.tabs.views.add_pestanha'),
    (r'^renametab/', 'widpy.tabs.views.cambiar_nombre_pes'),
    (r'^deletetab/', 'widpy.tabs.views.borrar_pes'),
    #(r'^inicio/','widpy.tabs.views.mostrar_pestanhas'),
    (r'^gt/(?P<t_id>\d+)/$','widpy.tabs.views.gt'),
    (r'^cambiar_orden_d/(?P<t_id>\d+)/$', 'widpy.tabs.views.cambiar_orden_d'),
    (r'^cambiar_orden_u/(?P<t_id>\d+)/$', 'widpy.tabs.views.cambiar_orden_u'),
    #(r'^search/change_theme/','widpy.tabs.views.mostrar_pestanhas'),
    (r'^search/change_theme/(?P<t_id>\d+)/$', 'widpy.themes.views.cambiarTema'),
    (r'^login/', login_up),
    (r'^manejo_cookies/', 'widpy.tabs.views.manejo_cookies'),
    #(r'^login/', login,{'template_name':'widpylogin/login.html'}),
    (r'^logout/', logged_out),
    (r'^solicitud/',solicitud),
    (r'^mensaje/', mensajepv),
	#(r'^inicio/editpestanha/$', 'widpy.widget.views.editcolumna'),
	#(r'^inicio/$', 'widpy.widget.views.inicio_registrados'),
    #(r'^registrar/', registrarse_widget),
    (r'^cerrarcuenta/', cerrarCuenta),
    (r'^editarperfil/', editar_perfil),
    (r'^recovery/',recovery),
    #(r'^search/add_widget/$', 'widpy.ecodatos.views.add_widget'),
    (r'^inicio/$', 'widpy.ecodatos.views.inicio_registrados'),
    (r'^editardisenho/', 'widpy.ecodatos.views.editcolumna'),
    (r'^eliminarcaja/', 'widpy.ecodatos.views.deletebox'),
    (r'^editarcolorcaja/', 'widpy.ecodatos.views.colorbox'),
    (r'^editaralturacaja/', 'widpy.ecodatos.views.tamanhobox'),
    (r'^movimientowidget/', 'widpy.ecodatos.views.moviendowidgets'),
    (r'^estadowidget/', 'widpy.ecodatos.views.estadowid'),
    (r'^googlesearch/', 'widpy.ecodatos.views.buscadorgoogle'),
   #(r'^search_categorias/$', 'prueba_busq.buscar.views.search_categorias'),
    #(r'^site_media/(?P.*)$', 'django.views.static.serve', {'document_root': '/var/www/prueba_busq/media'}),
    #(r'^site_media/(?P<path>.*)$', 'prueba_busq.views.static.serve', {'document_root': '/var/www/prueba_busq/buscar/templates'}),
)
